module.exports = app => {

  const { controller, middleware, router } = app;

  router.post('分配角色', '/user/relationship/createUserAndRole', middleware.jwt(), controller.relationship.createUserAndRole);
  router.post('更新角色', '/user/relationship/updateUserAndRole', middleware.jwt(), controller.relationship.updateUserAndRole);
  router.post('删除角色', '/user/relationship/deleteUserAndRole', middleware.jwt(), controller.relationship.deleteUserAndRole);
  router.post('获取权限', '/user/relationship/getRoleAndPermission', middleware.jwt(), controller.relationship.getRoleAndPermission);
  router.post('创建角色权限', '/user/relationship/createRoleAndPermission', middleware.jwt(), controller.relationship.createRoleAndPermission);
  router.post('编辑角色权限', '/user/relationship/updateRoleAndPermission', middleware.jwt(), controller.relationship.getRoleAndPermission);
  router.post('删除角色权限', '/user/relationship/deleteRoleAndPermission', middleware.jwt(), controller.relationship.deleteRoleAndPermission);
  router.get('初始化角色权限', '/user/relationship/init', controller.relationship.init);
};
